<?php 
	require_once ("./config.inc.php");
	require_once ("./include/mysql.inc.php");
	require_once ("./include/menu.inc.php");
	require './util/quote.php';
	
	$menuDao = new Menu();
	$menuRows = $menuDao->query();
?>
<html>
	<head>
		<link rel="stylesheet" type="text/css" href="./style/style.css" title="style" />
		<script type="text/javascript" src="./lib/jquery/jquery-1.6.js"></script>
		
		<link type="text/css" rel="stylesheet" href="./lib/syntaxhighlighter_3.0.83/styles/shCoreDefault.css">
		<script type="text/javascript" src="./lib/syntaxhighlighter_3.0.83/scripts/shCore.js"></script>
		<script type="text/javascript" src="./lib/syntaxhighlighter_3.0.83/scripts/shBrushJScript.js"></script>
		<script type="text/javascript" src="./lib/syntaxhighlighter_3.0.83/scripts/shBrushCpp.js"></script>
		<script type="text/javascript" src="./lib/syntaxhighlighter_3.0.83/scripts/shBrushCSharp.js"></script>
		<script type="text/javascript" src="./lib/syntaxhighlighter_3.0.83/scripts/shBrushCss.js"></script>
		<script type="text/javascript" src="./lib/syntaxhighlighter_3.0.83/scripts/shBrushJava.js"></script>
		<script type="text/javascript" src="./lib/syntaxhighlighter_3.0.83/scripts/shBrushPhp.js"></script>
		<script type="text/javascript" src="./lib/syntaxhighlighter_3.0.83/scripts/shBrushXml.js"></script>
		<script type="text/javascript" src="./lib/syntaxhighlighter_3.0.83/scripts/shBrushSql.js"></script>
		<script type="text/javascript" src="./lib/syntaxhighlighter_3.0.83/scripts/shBrushPython.js"></script>
		<!-- needim-noty-f288604 -->
		<script type="text/javascript" src="./lib/needim-noty-f288604/js/jquery.noty.js"></script>
		<link rel="stylesheet" type="text/css" href="./lib/needim-noty-f288604/css/noty_theme_facebook.css"/>
		<link rel="stylesheet" type="text/css" href="./lib/needim-noty-f288604/css/jquery.noty.css"/>
		<!-- online view -->
		<script type="text/javascript" src="./lib/jquery.media/jquery.media.js"></script>
		<!-- mine -->
		<script type="text/javascript" src="./lib/menu.js"></script>
		<!-- google site -->
			<script type="text/javascript">
		
			  var _gaq = _gaq || [];
			  _gaq.push(['_setAccount', 'UA-22729124-6']);
			  _gaq.push(['_trackPageview']);
			
			  (function() {
			    var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
			    ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
			    var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
			  })();
		
		</script>
		<!-- Baidu Button BEGIN -->
		<!--  -->
		<script type="text/javascript" id="bdshare_js" data="type=slide&amp;mini=1&amp;img=1&amp;uid=217713" ></script>
		<script type="text/javascript" id="bdshell_js"></script>
		<script type="text/javascript">
			document.getElementById("bdshell_js").src = "http://bdimg.share.baidu.com/static/js/shell_v2.js?cdnversion=" + new Date().getHours();
		</script>
		<!-- Baidu Button END -->
	</head>
	<body>
		<div id="header">
			<div id="logo">
				<div id="logo_text">
					<!-- class="logo_colour", allows you to change the colour of the text -->
					<h1>
						<a href="index.php">红色<span class="logo_colour">石头</span></a>
					</h1>
					<h2><?php echo quote::randomQuote(); ?></h2>
				</div>
			</div>
			<div id="menubar">
				<ul id="menu">
					<?php foreach ($menuRows as $menu) { ?>
					<li id="menu_<?php echo $menu[id]; ?>"><a href="<?php echo $menu[link]; ?>" <?php echo $menu[type]==2 ? "target='_blank'" :''; ?>><?php echo $menu[name]; ?></a></li>
					<?php } ?>
				</ul>
			</div>
		</div>
		<!-- douban music -->
		<!-- 
		<div>
			<embed height="30" width="261" style="position: fixed;right:0px; bottom:0px;" src="./res/music/douban_music.swf?url=./res/music/music&autoplay=0&isdemo=True" type="application/x-shockwave-flash" wmode="transparent">
		</div>
		 -->
 </body>
</html>